home *** CD-ROM | disk | FTP | other *** search
Wrap
Text File | 1996-05-01 | 17.9 KB | 694 lines | [ TEXT/MPS ]
; ; File: GXLayout.a ; ; Contains: QuickDraw GX layout routine interfaces. ; ; Version: Technology: Quickdraw GX 1.1 ; Release: Universal Interfaces 3.0d3 on Copland DR1 ; ; Copyright: © 1984-1996 by Apple Computer, Inc. All rights reserved. ; ; Bugs?: If you find a problem with this file, send the file and version ; information (from above) and the problem description to: ; ; Internet: apple.bugs@applelink.apple.com ; AppleLink: APPLE.BUGS ; ; IF &TYPE('__GXLAYOUT__') = 'UNDEFINED' THEN __GXLAYOUT__ SET 1 IF &TYPE('__CONDITIONALMACROS__') = 'UNDEFINED' THEN include 'ConditionalMacros.a' ENDIF IF &TYPE('__GXTYPES__') = 'UNDEFINED' THEN include 'GXTypes.a' ENDIF IF FOR_SYSTEM7_AND_SYSTEM8_COOPERATIVE THEN ; ; extern gxShape GXNewLayout(long textRunCount, const short textRunLengths[2147483647], const void *text[2147483647], long styleRunCount, const short styleRunLengths[2147483647], const gxStyle styles[2147483647], long levelRunCount, const short levelRunLengths[2147483647], const short levels[2147483647], const gxLayoutOptions *layoutOptions, const gxPoint *position) ; IF ¬ GENERATINGCFM THEN Macro _GXNewLayout move.w #$0000,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXNewLayout ENDIF ; ; extern long GXGetLayout(gxShape layout, void *text, long *styleRunCount, short styleRunLengths[2147483647], gxStyle styles[2147483647], long *levelRunCount, short levelRunLengths[2147483647], short levels[2147483647], gxLayoutOptions *layoutOptions, gxPoint *position) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayout move.w #$0001,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayout ENDIF ; ; extern void GXSetLayout(gxShape layout, long textRunCount, const short textRunLengths[2147483647], const void *text[2147483647], long styleRunCount, const short styleRunLengths[2147483647], const gxStyle styles[2147483647], long levelRunCount, const short levelRunLengths[2147483647], const short levels[2147483647], const gxLayoutOptions *layoutOptions, const gxPoint *position) ; IF ¬ GENERATINGCFM THEN Macro _GXSetLayout move.w #$0002,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetLayout ENDIF ; ; extern void GXDrawLayout(long textRunCount, const short textRunLengths[2147483647], const void *text[2147483647], long styleRunCount, const short styleRunLengths[2147483647], const gxStyle styles[2147483647], long levelRunCount, const short levelRunLengths[2147483647], const short levels[2147483647], const gxLayoutOptions *layoutOptions, const gxPoint *position) ; IF ¬ GENERATINGCFM THEN Macro _GXDrawLayout move.w #$0003,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXDrawLayout ENDIF ; ; extern void GXSetLayoutParts(gxShape layout, gxByteOffset oldStartOffset, gxByteOffset oldEndOffset, long newTextRunCount, const short newTextRunLengths[2147483647], const void *newText[2147483647], long newStyleRunCount, const short newStyleRunLengths[2147483647], const gxStyle newStyles[2147483647], long newLevelRunCount, const short newLevelRunLengths[2147483647], const short newLevels[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXSetLayoutParts move.w #$0004,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetLayoutParts ENDIF ; ; extern void GXSetLayoutShapeParts(gxShape layout, gxByteOffset startOffset, gxByteOffset endOffset, gxShape insert) ; IF ¬ GENERATINGCFM THEN Macro _GXSetLayoutShapeParts move.w #$0005,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetLayoutShapeParts ENDIF ; ; extern long GXGetLayoutParts(gxShape layout, gxByteOffset startOffset, gxByteOffset endOffset, void *text, long *styleRunCount, short styleRunLengths[2147483647], gxStyle styles[2147483647], long *levelRunCount, short levelRunLengths[2147483647], short levels[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayoutParts move.w #$0006,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayoutParts ENDIF ; ; extern gxShape GXGetLayoutShapeParts(gxShape layout, gxByteOffset startOffset, gxByteOffset endOffset, gxShape dest) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayoutShapeParts move.w #$0007,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayoutShapeParts ENDIF ; ; extern long GXGetLayoutGlyphs(gxShape layout, gxGlyphcode *glyphs, gxPoint positions[2147483647], long advance[2147483647], gxPoint tangents[2147483647], long *runCount, short styleRuns[2147483647], gxStyle glyphStyles[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayoutGlyphs move.w #$0008,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayoutGlyphs ENDIF ; ; extern gxByteOffset GXHitTestLayout(gxShape layout, const gxPoint *hitDown, gxHighlightType highlightType, gxLayoutHitInfo *hitInfo, gxShape hitTrackingArea) ; IF ¬ GENERATINGCFM THEN Macro _GXHitTestLayout move.w #$0009,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXHitTestLayout ENDIF ; ; extern gxShape GXGetLayoutHighlight(gxShape layout, gxByteOffset startOffset, gxByteOffset endOffset, gxHighlightType highlightType, gxShape highlight) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayoutHighlight move.w #$000A,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayoutHighlight ENDIF ; ; extern gxShape GXGetLayoutVisualHighlight(gxShape layout, gxByteOffset startOffset, long startLeadingEdge, gxByteOffset endOffset, long endLeadingEdge, gxHighlightType highlightType, gxShape highlight) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayoutVisualHighlight move.w #$000B,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayoutVisualHighlight ENDIF ; ; extern gxShape GXGetLayoutCaret(gxShape layout, gxByteOffset offset, gxHighlightType highlightType, gxCaretType caretType, gxShape caret) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayoutCaret move.w #$000C,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayoutCaret ENDIF ; ; extern gxByteOffset GXGetLayoutBreakOffset(gxShape layout, gxByteOffset startOffset, Fixed lineWidth, long hyphenationCount, const gxByteOffset hyphenationPoints[2147483647], Boolean *startIsStaked, gxByteOffset *priorStake, gxByteOffset *nextStake) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayoutBreakOffset move.w #$000D,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayoutBreakOffset ENDIF ; ; extern Fixed GXGetLayoutRangeWidth(gxShape layout, gxByteOffset startOffset, gxByteOffset endOffset, gxShape supplementaryText) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayoutRangeWidth move.w #$000E,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayoutRangeWidth ENDIF ; ; extern gxShape GXNewLayoutFromRange(gxShape layout, gxByteOffset startOffset, gxByteOffset endOffset, const gxLayoutOptions *layoutOptions, gxShape supplementaryText) ; IF ¬ GENERATINGCFM THEN Macro _GXNewLayoutFromRange move.w #$000F,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXNewLayoutFromRange ENDIF ; ; extern gxShape GXGetCaretAngleArea(gxShape layout, const gxPoint *hitPoint, gxHighlightType highlightType, gxShape caretArea, short *returnedRise, short *returnedRun) ; IF ¬ GENERATINGCFM THEN Macro _GXGetCaretAngleArea move.w #$0010,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetCaretAngleArea ENDIF ; ; extern void GXGetStyleBaselineDeltas(gxStyle baseStyle, gxBaselineType baseType, gxBaselineDeltas returnedDeltas) ; IF ¬ GENERATINGCFM THEN Macro _GXGetStyleBaselineDeltas move.w #$0011,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetStyleBaselineDeltas ENDIF ; ; extern gxByteOffset GXGetRightVisualOffset(gxShape layout, gxByteOffset currentOffset) ; IF ¬ GENERATINGCFM THEN Macro _GXGetRightVisualOffset move.w #$0012,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetRightVisualOffset ENDIF ; ; extern gxByteOffset GXGetLeftVisualOffset(gxShape layout, gxByteOffset currentOffset) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLeftVisualOffset move.w #$0013,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLeftVisualOffset ENDIF ; ; extern void GXGetCompoundCharacterLimits(gxShape layout, gxByteOffset trial, gxByteOffset *minOffset, gxByteOffset *maxOffset, Boolean *onBoundary) ; IF ¬ GENERATINGCFM THEN Macro _GXGetCompoundCharacterLimits move.w #$0014,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetCompoundCharacterLimits ENDIF ; ; extern void GXGetOffsetGlyphs(gxShape layout, gxByteOffset trial, long leadingEdge, gxLayoutOffsetState *offsetState, unsigned short *firstGlyph, unsigned short *secondGlyph) ; IF ¬ GENERATINGCFM THEN Macro _GXGetOffsetGlyphs move.w #$0015,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetOffsetGlyphs ENDIF ; ; extern void GXGetGlyphOffset(gxShape layout, long trial, long onLeftTop, gxByteOffset *offset, Boolean *leadingEdge, Boolean *wasRealCharacter) ; IF ¬ GENERATINGCFM THEN Macro _GXGetGlyphOffset move.w #$0016,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetGlyphOffset ENDIF ; ; extern void GXGetLayoutSpan(gxShape layout, Fixed *lineAscent, Fixed *lineDescent) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayoutSpan move.w #$0017,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayoutSpan ENDIF ; ; extern void GXSetLayoutSpan(gxShape layout, Fixed lineAscent, Fixed lineDescent) ; IF ¬ GENERATINGCFM THEN Macro _GXSetLayoutSpan move.w #$0018,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetLayoutSpan ENDIF ; ; extern Fixed GXGetLayoutJustificationGap(gxShape layout) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayoutJustificationGap move.w #$0279,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayoutJustificationGap ENDIF ; ; extern void GXGetLayoutJustificationFactors(gxShape layout, Fixed constrainedFactors[2147483647], Fixed unconstrainedFactors[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXGetLayoutJustificationFactors move.w #$027A,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetLayoutJustificationFactors ENDIF ; ; extern void GXSetStyleRunControls(gxStyle target, const gxRunControls *runControls) ; IF ¬ GENERATINGCFM THEN Macro _GXSetStyleRunControls move.w #$0019,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetStyleRunControls ENDIF ; ; extern void GXSetStyleRunPriorityJustOverride(gxStyle target, const gxPriorityJustificationOverride *priorityJustificationOverride) ; IF ¬ GENERATINGCFM THEN Macro _GXSetStyleRunPriorityJustOverride move.w #$001A,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetStyleRunPriorityJustOverride ENDIF ; ; extern void GXSetStyleRunGlyphJustOverrides(gxStyle target, long count, const gxGlyphJustificationOverride glyphJustificationOverrides[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXSetStyleRunGlyphJustOverrides move.w #$001B,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetStyleRunGlyphJustOverrides ENDIF ; ; extern void GXSetStyleRunGlyphSubstitutions(gxStyle target, long count, const gxGlyphSubstitution glyphSubstitutions[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXSetStyleRunGlyphSubstitutions move.w #$001C,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetStyleRunGlyphSubstitutions ENDIF ; ; extern void GXSetStyleRunFeatures(gxStyle target, long count, const gxRunFeature runFeatures[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXSetStyleRunFeatures move.w #$001D,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetStyleRunFeatures ENDIF ; ; extern void GXSetStyleRunKerningAdjustments(gxStyle target, long count, const gxKerningAdjustment kerningAdjustments[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXSetStyleRunKerningAdjustments move.w #$001E,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetStyleRunKerningAdjustments ENDIF ; ; extern void GXSetShapeRunControls(gxShape target, const gxRunControls *runControls) ; IF ¬ GENERATINGCFM THEN Macro _GXSetShapeRunControls move.w #$001F,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetShapeRunControls ENDIF ; ; extern void GXSetShapeRunPriorityJustOverride(gxShape target, const gxPriorityJustificationOverride *priorityJustificationOverride) ; IF ¬ GENERATINGCFM THEN Macro _GXSetShapeRunPriorityJustOverride move.w #$0020,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetShapeRunPriorityJustOverride ENDIF ; ; extern void GXSetShapeRunGlyphJustOverrides(gxShape target, long count, const gxGlyphJustificationOverride glyphJustificationOverrides[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXSetShapeRunGlyphJustOverrides move.w #$0021,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetShapeRunGlyphJustOverrides ENDIF ; ; extern void GXSetShapeRunGlyphSubstitutions(gxShape target, long count, const gxGlyphSubstitution glyphSubstitutions[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXSetShapeRunGlyphSubstitutions move.w #$0022,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetShapeRunGlyphSubstitutions ENDIF ; ; extern void GXSetShapeRunFeatures(gxShape target, long count, const gxRunFeature runFeatures[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXSetShapeRunFeatures move.w #$0023,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetShapeRunFeatures ENDIF ; ; extern void GXSetShapeRunKerningAdjustments(gxShape target, long count, const gxKerningAdjustment kerningAdjustments[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXSetShapeRunKerningAdjustments move.w #$0024,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXSetShapeRunKerningAdjustments ENDIF ; ; extern long GXGetStyleRunControls(gxStyle source, gxRunControls *runControls) ; IF ¬ GENERATINGCFM THEN Macro _GXGetStyleRunControls move.w #$0025,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetStyleRunControls ENDIF ; ; extern long GXGetStyleRunPriorityJustOverride(gxStyle source, gxPriorityJustificationOverride *priorityJustificationOverride) ; IF ¬ GENERATINGCFM THEN Macro _GXGetStyleRunPriorityJustOverride move.w #$0026,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetStyleRunPriorityJustOverride ENDIF ; ; extern long GXGetStyleRunGlyphJustOverrides(gxStyle source, gxGlyphJustificationOverride glyphJustificationOverrides[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXGetStyleRunGlyphJustOverrides move.w #$0027,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetStyleRunGlyphJustOverrides ENDIF ; ; extern long GXGetStyleRunGlyphSubstitutions(gxStyle source, gxGlyphSubstitution glyphSubstitutions[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXGetStyleRunGlyphSubstitutions move.w #$0028,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetStyleRunGlyphSubstitutions ENDIF ; ; extern long GXGetStyleRunFeatures(gxStyle source, gxRunFeature runFeatures[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXGetStyleRunFeatures move.w #$0029,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetStyleRunFeatures ENDIF ; ; extern long GXGetStyleRunKerningAdjustments(gxStyle source, gxKerningAdjustment kerningAdjustments[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXGetStyleRunKerningAdjustments move.w #$002A,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetStyleRunKerningAdjustments ENDIF ; ; extern long GXGetShapeRunControls(gxShape source, gxRunControls *runControls) ; IF ¬ GENERATINGCFM THEN Macro _GXGetShapeRunControls move.w #$002B,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetShapeRunControls ENDIF ; ; extern long GXGetShapeRunPriorityJustOverride(gxShape source, gxPriorityJustificationOverride *priorityJustificationOverride) ; IF ¬ GENERATINGCFM THEN Macro _GXGetShapeRunPriorityJustOverride move.w #$002C,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetShapeRunPriorityJustOverride ENDIF ; ; extern long GXGetShapeRunGlyphJustOverrides(gxShape source, gxGlyphJustificationOverride glyphJustificationOverrides[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXGetShapeRunGlyphJustOverrides move.w #$002D,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetShapeRunGlyphJustOverrides ENDIF ; ; extern long GXGetShapeRunGlyphSubstitutions(gxShape source, gxGlyphSubstitution glyphSubstitutions[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXGetShapeRunGlyphSubstitutions move.w #$002E,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetShapeRunGlyphSubstitutions ENDIF ; ; extern long GXGetShapeRunFeatures(gxShape source, gxRunFeature runFeatures[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXGetShapeRunFeatures move.w #$002F,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetShapeRunFeatures ENDIF ; ; extern long GXGetShapeRunKerningAdjustments(gxShape source, gxKerningAdjustment kerningAdjustments[2147483647]) ; IF ¬ GENERATINGCFM THEN Macro _GXGetShapeRunKerningAdjustments move.w #$0030,D0 dc.w $A832 EndM ELSE IMPORT_CFM_FUNCTION GXGetShapeRunKerningAdjustments ENDIF ENDIF ENDIF ; __GXLAYOUT__